package com.youkeda.kafka.study.util;

import java.util.Arrays;
import java.util.Collections;
import java.util.List;

public class NameUtil {
    private static final String[] NAMES =
        {"达设", "祁扑中", "诸卡功", "万许", "柯引", "韶讨", "朱巴", "经旦犯", "池乡", "车乃团", "葛允", "甘井", "汤讨", "荀卫叼", "后匠勺", "赖伙", "连白",
            "段而", "邱井本", "居布认", "戎斥", "密占", "葛庆凶", "施勺", "申江亏", "隗已", "靳加", "顾心", "龚只山", "真帅", "桂收匹", "练夺", "幸节", "印史",
            "京色朱", "龚纠已", "荀并乞", "向匆刃", "裴务", "艾乡讲"};

    /**
     * 取得打乱顺序的一批名字，相当于随机名字了。
     *
     * @param count
     * @return
     */
    public static List<String> shuffle(int count) {
        List<String> names = Arrays.asList(NAMES);
        Collections.shuffle(names);
        return names.subList(0, count);
    }

    public static int getLength() {
        return NAMES.length;
    }
}
